package com.hzj.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;

import java.io.Serializable;
import java.util.List;
import java.util.Set;

import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * <p>
 *
 * </p>
 *
 * @author hzj
 * @since 2021-03-19
 */
@Data

@EqualsAndHashCode(callSuper = false)
public class VoteSubject implements Serializable {
    public VoteSubject(Long vsId, String vsTitle, Integer vsType, List<VoteOption> voteOptions, List<VoteItem> voteItems) {
        this.vsId = vsId;
        this.vsTitle = vsTitle;
        this.vsType = vsType;
        this.voteOptions = voteOptions;
        this.voteItems = voteItems;
    }

    public VoteSubject() {
    }

    private static final long serialVersionUID = 1L;

    /**
     * 自身id
     */
    @TableId(value = "vs_id", type = IdType.INPUT)
    private Long vsId;

    /**
     * 主题内容
     */
    private String vsTitle;

    /**
     * 选项类型1.单选 2.多选
     */
    private Integer vsType;
    @TableField(exist = false)
    private List<VoteOption> voteOptions;
    @TableField(exist = false)
    private List<VoteItem> voteItems;
}
